PATHMac OS 8 and 9 Developer Documentation > Human Interface Toolbox > Appearance Manager >

Programming With the Appearance Manager


DrawThemeTrackTickMarks

Draws tick marks for a track.

pascal OSStatus DrawThemeTrackTickMarks (
                     const ThemeTrackDrawInfo *drawInfo,
                     ItemCount numTicks,
                     ThemeEraseUPP eraseProc,
                     UInt32 eraseData);
drawInfo
A pointer to a structure of type ThemeTrackDrawInfo . Before calling DrawThemeTrackTickMarks , set the structure to describe the current visual characteristics of the track. Because, under Appearance Manager 1.1, sliders are the only track type to support tick marks, you should set the kind field of the ThemeTrackDrawInfo structure to kThemeSlider and fill out the remainder of the structure appropriately for a slider track. You should set the bounds field of the ThemeTrackDrawInfo structure to the boundary of the track itself, not including the area that contains the tick marks; you can obtain the actual bounding rectangle of the track by calling the function GetThemeTrackBounds . DrawThemeTrackTickMarks draws the tick marks outside the track's bounding rectangle, above or below the track depending on the thumb direction indicated by the drawInfo.trackInfo.slider.thumbDir field.
numTicks
A value of type ItemCount . Pass an unsigned 32-bit value specifying the number of tick marks to be drawn.
eraseProc
A value of type ThemeEraseUPP . If you have a custom background, pass a universal procedure pointer to an application-defined function such as that described in MyThemeEraseProc . DrawThemeTrackTickMarks calls that function to erase the background before drawing tick marks. If you pass NULL , no erasing occurs.
eraseData
An unsigned 32-bit integer. Provide any data to be passed in to the callback function specified in the eraseProc parameter.
function result
A result code; see Result Codes .
DISCUSSION

Your application can call the DrawThemeTrackTickMarks function to draw theme-compliant tick marks for a slider control. (Under Appearance Manager 1.1, sliders are the only track type that supports tick marks.) To draw a track control, call the function DrawThemeTrack . To draw a single tick mark, call the function DrawThemeTickMark .

VERSION NOTES

Available with Appearance Manager 1.1 and later.


© 1999 Apple Computer, Inc. – (Last Updated 29 April 99)